<?php
    include_once("../arc2/ARC2.php");

    $config = array(
        /* db */
        'db_host' => 'localhost', /* optional, default is localhost */
        'db_name' => 'sellcenter',
        'db_user' => 'root',
        'db_pwd' => '',

        /* store name */
        'store_name' => 'my_store',

        /* endpoint */
        'endpoint_features' => array(
            'select', 'construct', 'ask', 'describe', 
            'load', 'insert', 'delete', 
            'dump' /* dump is a special command for streaming SPOG export */
        ),
        'endpoint_timeout' => 60, /* not implemented in ARC2 preview */
        'endpoint_read_key' => '', /* optional */
        'endpoint_write_key' => '', /* optional, but without one, everyone can write! */
        'endpoint_max_limit' => 250, /* optional */
        'store_allow_extension_functions' => 1,
    );

    /* instantiation */
    $store = ARC2::getStoreEndpoint($config);

    if (!$store->isSetUp()) {
        $store->setUp(); /* create MySQL tables */
    }   
    
    /**
    *   EXAMPLE LOAD DATA IN TO ARC2STORE
    *   $store->query('LOAD <http://www.daml.org/2003/01/periodictable/PeriodicTable.owl>'); 
    *   $store->query('LOAD <http://localhost/senmantic/id/pig>');
    *   $store->query('LOAD <http://localhost/senmantic/id/cat>');
    */
    
    /** Load data*/
    //$store->query('LOAD <http://localhost/tasklist/id/bussiness>');
    //$store->query('LOAD <http://localhost/tasklist/id/manufacturer_8>');
    
    /* request handling */
    $store->go();
?>
